package com.flame.workflow.re.mapper;

import com.flame.workflow.re.controller.vo.FormComponentVo;
import com.flame.workflow.re.entity.FormComponent;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * flame_workflow_re_form_item 流程表单项定义表
 *
 * @author 吴欣童
 * @since 2023-05-04 19:53:45
 */
@Mapper
public interface FormComponentMapper {

    List<FormComponent> page(FormComponentVo formComponentVo);

    void insert(FormComponent formComponent);

    void deleteById(@Param("modelId") Long modelId, @Param("modelVersion") Integer modelVersion, @Param("componentCode") String componentCode);

    FormComponent findById(@Param("modelId") Long modelId, @Param("modelVersion") Integer modelVersion, @Param("componentCode") String componentCode);

    List<FormComponent> listByModelId(@Param("modelId") Long modelId, @Param("modelVersion") Integer modelVersion);

    void deleteByModelId(@Param("modelId") Long modelId, @Param("modelVersion") Integer modelVersion);
}